package com.qiumo.gmtool.controller;

import com.qiumo.gmtool.common.RetResult;
import com.qiumo.gmtool.service.SignDataService;
import lombok.RequiredArgsConstructor;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * 签到
 */
@RestController
@RequiredArgsConstructor
@RequestMapping("/sign")
public class SignDataController {

    private final SignDataService signDataService;

    /**
     * 获取本月签到配置
     */
    @GetMapping("/list")
    public RetResult list() {
        return signDataService.getListByMonth();
    }

    /**
     * 签到
     */
    @GetMapping("/sign")
    public RetResult sign() {
        return signDataService.sign();
    }

}
